package learn.emp02.ex04;

import java.math.BigDecimal;
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner scanner = new Scanner(System.in);
        while (scanner.hasNext()){
            String line = scanner.nextLine();
            String[] num = line.split(" ");
            BigDecimal num1 = new BigDecimal(num[0]);
            BigDecimal num2 = new BigDecimal(num[1]);
            BigDecimal sum = num1.add(num2);
            BigDecimal product = num1.multiply(num2);
            System.out.println(sum.toString());
            System.out.println(product.toString());
        }
        scanner.close();
    }
}
